Repository navigation
Add bounded feature flag evaluation EVP reporting - #4288
Conversation
|
Benchmarks [ tracer ]Benchmark execution time: 2026-10-20 22:46:04 Comparing candidate commit 37e3d84 in PR branch Found 2 performance improvements and 0 performance regressions! Performance is the same for 191 metrics, 1 unstable metrics.
|
…agentless-20261008 # Conflicts: # components-rs/common.h # libdatadog
…agentless-20261008 # Conflicts: # libdatadog
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
Note to self: performanceFresh local Median per-evaluation time, in microseconds (median of three runs; application restricted to CPU 0):
Measurement scopePHP 8.2.34 NTS / Linux ARM64, JIT disabled, default sidecar connection mode. Four scalar context fields, ten repeated identities, 500 warmup evaluations and 3,000 or 30,000 measured evaluations per run. Native and OpenFeature × one/two-CPU application affinity × 1,000/10,000 requested evaluations/sec × baseline/disabled/protected/consented × three repeats = 96 runs. The normal shared sidecar was a separate process pinned to CPU 0 and reused across runs; the mock Agent ran on CPU 14. Both SDKs use the same native commit These are short SDK-call microbenchmarks, not full PHP-FPM request latency or statistical performance-equivalence evidence. Disabled-mode differences are shown without claiming an improvement. The general CI benchmark report is separate and was still running when this comment was posted. |
Drop the owned error returned by the shutdown flush while preserving best-effort error handling. Add a broken-connection regression verified with Valgrind leak checking.
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
…agentless-20261008
There was a problem hiding this comment.
More details
Evaluation reporting uses the final mapped outcome and consent captured with that evaluation. The completed static review identified no reportable defects; native transport and lifecycle behavior remain unverified at runtime.
🤖 Bits Code Review · Commit ce0ad1f
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: ce0ad1f61c
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
|
Could you please split the testsuites? Use phpunit tests (you can use phpt files there if you want - but some tests could benefit from proper API/helper reuse, so maybe a proper class test makes for nicer code?) for stuff testing src/. Accessing |
Include flag evaluations in signal flushes and use resolved request identity. Capture OpenFeature evaluation metadata per invocation and submit the final hook outcome without changing immediate native reporting. Cover signal delivery, default and updated identity, terminal hook failures, nested calls, fibers, and raw payload privacy.
Keep Valgrind runtime checks and all signal-flush assertions while avoiding the slow final scan of libdatadog shared-memory reservations left by intentional _exit. Other tests retain their existing leak-check settings.
…agentless-20261008
|
✅ lgtm |
|
/code blockers |
|
View all feedbacks in Devflow UI.
Checking merge blockers for #4288...
Detected 1 merge blocker(s) to address: 🔴 Blocking
⚪ Unknown
|
|
/code blockers |
|
View all feedbacks in Devflow UI.
Checking merge blockers for #4288...
No merge blockers detected. ⚪ Unknown
|
Motivation
PHP already reports feature-flag exposures. This adds privacy-safe
flagevaluationtrack EVP events for both the native PHP client and OpenFeature, so Datadog can report how often flags are evaluated without sending customer identity or context by default.Changes and key decisions
observeFullEvaluationData: true, hash the targeting key and omit evaluation context. With consent, include bounded scalar context; oversized/degraded observations can omit identity and context.DD_FLAGGING_EVALUATION_COUNTS_ENABLEDindependently of OTel metrics. Fixed-name rejection metrics report drops through ordinary telemetry, without per-evaluation logging.flagevaluationevents, with the PHP SDK name/version on both writers; retain Remote Config's Agent EVP v2 route.Builds on merged libdatadog #2605 and #2614, and continues the intent of PHP #3984.
The earlier native integration draft is libdatadog #2645; this branch now uses the same libdatadog commit as
master, rather than a separate dependency bump.Agentless activation/CDN wiring remains separate, following settings #4195 and poller #4196.
This PR enables Agent-backed delivery, not agentless PHP.
Blast radius and tradeoffs
Testing
External comparisons below used
8d7488806versusmaster401174500. The only later commit,ce0ad1f61, fixes shutdown error cleanup and adds its regression test; CI and local leak checks cover that final commit.flagevaluationevents from this branch. Live consent was true; absent/false consent is covered separately by system-tests.ce0ad1f61. This is separate from the FFE-specific overhead measured above.